project(hot-rowex)

include_directories(include)

set(NAMESPACE hot/rowex)
set(HDR_NAMESPACE ${CMAKE_CURRENT_SOURCE_DIR}/include/${NAMESPACE})

set(hot-rowex-lib-HEADERS ${hot-rowex-lib-HEADERS} ${HDR_NAMESPACE}/HOTRowexChildPointer.hpp)
set(hot-rowex-lib-HEADERS ${hot-rowex-lib-HEADERS} ${HDR_NAMESPACE}/HOTRowexChildPointerInterface.hpp)
set(hot-rowex-lib-HEADERS ${hot-rowex-lib-HEADERS} ${HDR_NAMESPACE}/EpochBasedMemoryReclamationStrategy.hpp)
set(hot-rowex-lib-HEADERS ${hot-rowex-lib-HEADERS} ${HDR_NAMESPACE}/HOTRowexIteratorBufferStates.hpp)
set(hot-rowex-lib-HEADERS ${hot-rowex-lib-HEADERS} ${HDR_NAMESPACE}/HOTRowexFirstInsertLevel.hpp)
set(hot-rowex-lib-HEADERS ${hot-rowex-lib-HEADERS} ${HDR_NAMESPACE}/HOTRowexInsertStack.hpp)
set(hot-rowex-lib-HEADERS ${hot-rowex-lib-HEADERS} ${HDR_NAMESPACE}/HOTRowexInsertStackEntry.hpp)
set(hot-rowex-lib-HEADERS ${hot-rowex-lib-HEADERS} ${HDR_NAMESPACE}/MemoryGuard.hpp)
set(hot-rowex-lib-HEADERS ${hot-rowex-lib-HEADERS} ${HDR_NAMESPACE}/HOTRowex.hpp)
set(hot-rowex-lib-HEADERS ${hot-rowex-lib-HEADERS} ${HDR_NAMESPACE}/HOTRowexInterface.hpp)
set(hot-rowex-lib-HEADERS ${hot-rowex-lib-HEADERS} ${HDR_NAMESPACE}/HOTRowexIterator.hpp)
set(hot-rowex-lib-HEADERS ${hot-rowex-lib-HEADERS} ${HDR_NAMESPACE}/HOTRowexIteratorBufferState.hpp)
set(hot-rowex-lib-HEADERS ${hot-rowex-lib-HEADERS} ${HDR_NAMESPACE}/HOTRowexIteratorBufferStates.hpp)
set(hot-rowex-lib-HEADERS ${hot-rowex-lib-HEADERS} ${HDR_NAMESPACE}/HOTRowexIteratorStackEntry.hpp)
set(hot-rowex-lib-HEADERS ${hot-rowex-lib-HEADERS} ${HDR_NAMESPACE}/HOTRowexIteratorStackState.hpp)
set(hot-rowex-lib-HEADERS ${hot-rowex-lib-HEADERS} ${HDR_NAMESPACE}/HOTRowexNode.hpp)
set(hot-rowex-lib-HEADERS ${hot-rowex-lib-HEADERS} ${HDR_NAMESPACE}/HOTRowexNodeInterface.hpp)
set(hot-rowex-lib-HEADERS ${hot-rowex-lib-HEADERS} ${HDR_NAMESPACE}/HOTRowexNodeBase.hpp)
set(hot-rowex-lib-HEADERS ${hot-rowex-lib-HEADERS} ${HDR_NAMESPACE}/HOTRowexNodeBaseInterface.hpp)
set(hot-rowex-lib-HEADERS ${hot-rowex-lib-HEADERS} ${HDR_NAMESPACE}/HOTRowexIteratorEndToken.hpp)
set(hot-rowex-lib-HEADERS ${hot-rowex-lib-HEADERS} ${HDR_NAMESPACE}/SpinLock.hpp)
set(hot-rowex-lib-HEADERS ${hot-rowex-lib-HEADERS} ${HDR_NAMESPACE}/ThreadSpecificEpochBasedReclamationInformation.hpp)

add_library(hot-rowex-lib INTERFACE)
target_sources(hot-rowex-lib INTERFACE ${hot-rowex-lib-HEADERS})
target_include_directories(hot-rowex-lib INTERFACE "${PROJECT_SOURCE_DIR}/include")
target_link_libraries(hot-rowex-lib INTERFACE content-helpers-lib hot-commons-lib ${TC_MALLOC_LIBRARY} TBB::tbb)
